package cn.bone.alibabacloud.service.impl;

import cn.bone.alibabacloud.mapper.StorageMapper;
import cn.bone.alibabacloud.service.IStorageService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
@Slf4j
public class StorageServiceImpl implements IStorageService {

    @Resource
    private StorageMapper storageMapper;

    public void decrease(Integer productId, Integer count){

        log.info("---> 做扣减库存count");
        storageMapper.decrease(productId, count);
        log.info("---> 做扣减库存count 结束");
    }
}
